<?php

/*************************************************************************
 * File Name:
 * Author: fanmh
 * Mail: fanmh@yisa.com
 * Created Time:
 * Edit Time:
 * Description:
 ************************************************************************/

for ($i = 1 ;$i<10 ;$i++) {
    for ($j = 1 ;$j<=$i ;$j++) {
        echo strval($i) . "*" . strval($j) . "=" . strval($i*$j);
        echo PHP_EOL;
    }
    echo "<br>";
}

$cheng = [1,2,3,4,5,6,7,8,9];

foreach ($cheng as $k) {
    foreach ($cheng as $ke) {
        if ($ke <= $k) {
            echo strval($k) . "*" . strval($ke) . "=" . strval($k*$ke);
            echo PHP_EOL;
        }
    }
    echo "<br>";
}
?>